<?php
$this->pageTitle=Yii::app()->name . ' - Войти';
$this->breadcrumbs=array(
	'Войти',
);
?>

<?php echo CHtml::errorSummary($model); ?>

<div class="form login">
<?php echo CHtml::beginForm(); ?>
<h2 class="maintitle">Вход</h3>
<h3 class="bar">Пожалуйста заполните форму для входа:</h3>

	<div class="row">
		<?php echo CHtml::activeLabel($model,'username'); ?>
		<?php echo CHtml::activeTextField($model,'username',array('size'=>25,'maxlength'=>25)); ?>
		<?php echo CHtml::error($model,'username'); ?>
	</div>

	<div class="row">
		<?php echo CHtml::activeLabel($model,'password'); ?>
		<?php echo CHtml::activePasswordField($model,'password',array('size'=>25,'maxlength'=>25)); ?>
		<?php echo CHtml::error($model,'password'); ?>
		<span class="hint">Hint: You may login with <tt>demo/demo</tt> or <tt>admin/admin</tt>.</span>
	</div>

	<div class="row checkbox">
		<?php echo CHtml::activeCheckBox($model,'rememberMe'); ?>
		<?php echo CHtml::activeLabel($model,'rememberMe'); ?>
	</div>

	<div class="buttons">
		<?php echo CHtml::submitButton('Login'); ?>
	</div>

<?php echo CHtml::endForm(); ?>
</div><!-- form -->

<?php
$form = new CForm(array(
    'elements'=>array(
        'username'=>array(
            'type'=>'text',
            'maxlength'=>32,
        ),
        'password'=>array(
            'type'=>'password',
            'maxlength'=>32,
        ),
        'rememberMe'=>array(
            'type'=>'checkbox',
        )
    ),

    'buttons'=>array(
        'login'=>array(
            'type'=>'submit',
            'label'=>'Login',
        ),
    ),
), $model);
?>